package com.cloud.businesscomment.service.serviceImpl;

import com.cloud.businesscomment.dao.Goods_orderMapper;
import com.cloud.businesscomment.service.GoodsOrderService;
import com.cloud.commonapi.model.Goods_order;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author 陈楚城
 * @date 2019/9/30 15:04
 */
@Service
public class GoodsOrderServiceImpl implements GoodsOrderService {
    @Autowired
    private Goods_orderMapper goods_orderMapper;
    @Override
    public int addorder(Goods_order goods_order) {
        return goods_orderMapper.insert(goods_order);
    }

    @Override
    public Goods_order getorder(Integer id) {
        return goods_orderMapper.selectByPrimaryKey(id);
    }

    @Override
    public List<Goods_order> list(Integer accountId) {
        return goods_orderMapper.list(accountId);
    }

    @Override
    public int updateorder(Goods_order goods_order) {
        return goods_orderMapper.updateByPrimaryKeySelective(goods_order);
    }
}
